<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>管理员列表--layui后台管理模板</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">
    <link rel="stylesheet" href="/admin/layui/css/layui.css" media="all" />
    <link rel="stylesheet" href="/admin/css/font_eolqem241z66flxr.css" media="all" />
    <script language="javascript" type="text/javascript" src="/admin/js/jquery-3.1.1.js"></script>
    <script type="text/javascript" src="/admin/js/mylayer.js"></script>
    <style type="text/css">
        .layui-table td, .layui-table th{ text-align: center; }
        .layui-table td{ padding:5px; }
        .childrenBody_menu { width: 100%; height: 30px; margin-top: 10px;}
        .childrenBody_menu a { display: inline-block; width: auto; background: #c3c3c3;  height: 30px; line-height: 30px; text-align: center; padding: 0 10px; color: #333;}
        .childrenBody_menu a.action { background: #249D80; color: #fff;}
        .childrenbody_content { width: 100%; height: 600px; border: 1px solid #eee; padding-top: 20px;}
        .form_con { display: none;}
        .children_meun { height: 30px; margin-bottom: 15px; text-align: right;}
        .children_meun a { display: inline-block; width: auto; color: #333; text-align: center;line-height: 30px; height: 30px; background: #eee; padding:0 10px; margin-right: 10px;}
        .upload_layer { width: 500px; height: 300px; background: #fff; position: absolute; top: 50%;  left: 38%; transition: .5s, transform 0.2s;
            -moz-transition: .5s, -moz-transform 0.2s;
            -webkit-transition: .5s, -webkit-transform 0.2s;
            -o-transition: .5s, -o-transform 2s;}
        .layer_title { width: 98%; height: 40px; line-height: 40px; color: #fff; padding-left: 2%; background: #3c3c3c;}
        .window_layer { width: 100%; height: 100%; position: fixed; top: 0; left: 0; background: rgba(0,0,0,0.5);}
        .layer_con { width: 90%; height: auto; margin: 0 auto;}
        .rollpic-show { width: 100%; height: 100px; margin-top: 15px; position: relative;}
        .rollpic-show img { width: 100%; height: 100%;}
        .rollpic_link { margin-top: 15px;}
        .rollpic_btn { margin-top: 15px;}
        .layer_colse { display: inline-block; width: 25px; height: 25px;
            float: right; }
        .upload_btn { width: 100%; height: 100px; position: absolute; top: 0; left: 0; opacity: 0; background: rgba(0,0,0,.5)}
        .upload_btn_lay { width: 40px; height: 40px; margin: 0 auto; margin-top: 25px; background: url("__PUBLIC__/images/upload_pic.png"); background-size: 100% 100%;}
        .upload_btn input { opacity: 0;}
        .upload_btn:hover { opacity: 1;}
    </style>
</head>
<body class="childrenBody">
<div class="childrenBody_menu_title">
    管理员列表
</div>
<div class="childrenBody_menu">
    <a href="javascript:;" class="action" id="tab_setting_1" onclick="SwapTab('setting','action','',4,1);">管理员列表</a>
</div>
<div class="childrenbody_content">
    <div class="form_con" style="display: block;" id="div_setting_1">
        <table class="layui-table" lay-even="" lay-skin="row">
            <colgroup>
                <col width="50">
                <col width="200">
                <col width="400">
                <col width="">
            </colgroup>
            <thead>
            <tr style="height: 40px">
                <th>id</th>
                <th>用户名</th>
                <th>所属角色</th>
                <th>最后登录IP</th>
                <th>最后登录时间</th>
                <th>操作</th>
            </tr>
            </thead>
            <tbody>
            @foreach($adminlist['data'] as $vo)
            <tr id="roll_{{$vo['id']}}">
                <td><input type="text" style="width: 20px" value='{{$vo['id']}}'></td>
                <td>{{$vo['adminname']}}</td>
                <td>@if($vo['id']==1)超级管理员@endif @if($vo['id']!=1)普通管理员@endif</td>
                <td>{{$vo['lastlogip']}}</td>
                <td>{{date("Y-m-d",$vo['lastlogtime'])}}</td>
                <td> <button class="layui-btn layui-btn-normal" onclick="window.location.href='/admin/siteconfig/editadminuser?adminid={{$vo['id']}}'">修改</button>@if($vo['id']!=1) <button class="layui-btn layui-btn-normal" onclick="showlayer({{$vo['id']}},'update')" style="background: #ccc;">删除</button>@endif</td>
            </tr>
            @endforeach
            </tbody>
        </table>
        <div class="op">
            <button class="layui-btn layui-btn-normal" onclick="window.location.href='/admin/siteconfig/addadminuser'">新增管理员</button>
        </div>
    </div>
</div>
</body>
</html>
<!--<div class="window_layer">-->
    <!--<div class="upload_layer">-->
         <!--<div class="layer_title">-->
              <!--上传-->
         <!--</div>-->
         <!--<div class="layer_con">-->

         <!--</div>-->
    <!--</div>-->
<!--</div>-->
<script type="text/javascript" src="__PUBLIC__/newAdmin/layui/layui.js"></script>
<script>
    function SwapTab(name,cls_show,cls_hide,cnt,cur){
        for(i=1;i<=cnt;i++){
            if(i==cur){
                $('#div_'+name+'_'+i).show();
                $('#tab_'+name+'_'+i).attr('class',cls_show);
            }else{
                $('#div_'+name+'_'+i).hide();
                $('#tab_'+name+'_'+i).attr('class',cls_hide);
            }
        }
    }
</script>
